<?php

namespace app\index\widget;

use think\Controller;

class Widget extends Controller
{

    /**
     * 饼状图
     * @param type $id
     * @param type $data
     * @param type $title
     * @return type
     */
    public function pieChart($id, $data, $title = '')
    {
        $this->assign([
            'id' => $id,
            'data' => $data,
        ]);
        return $this->fetch('widget/column_chart');
    }

}
